/*
 * @Author: your name
 * @Date: 2021-11-30 20:04:12
 * @LastEditTime: 2021-11-30 20:14:22
 * @LastEditors: Please set LastEditors
 * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 * @FilePath: \li-yuwei\client\src\utils\getIp.js
 */
export default function getIP() {
    let script = document.createElement("script");
    script.type = "text/javascript";
    script.src = "http://pv.sohu.com/cityjson?ie=utf-8";
    document.head.appendChild(script);
    let script2 = document.createElement("script");
    script2.type = "text/javascript";
    script2.innerText = "sessionStorage.setItem('ip', returnCitySN[\"cip\"]);";
    script2.innerText =
        "sessionStorage.setItem('cname', returnCitySN[\"cname\"]);";
    document.head.appendChild(script2);
}